package com.hackordie.operations.updates;

import com.hackordie.commons.HackOrDieResult;
import com.hackordie.commons.authorities.Profile;
import com.hackordie.exceptions.HackOrDieException;
import com.hackordie.operations.AHackOrDieOperationProfile;

public class UpdateProfile extends AHackOrDieOperationProfile {

	private final Profile profile;

	public UpdateProfile(Profile profile) {
		super();
		this.profile = profile;
	}

	@Override
	protected boolean checkParameters() {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	protected HackOrDieResult executeOperation() throws HackOrDieException {
		profileDao.update(profile);
		result.setObject(profile);
		return result;
	}

}
